package com.linkvin.ec.hcs.service.util.enums;

public enum LockedEnum {

	LOCKED((byte)0, "锁定"),
	NORMAL((byte)1, "正常");

	private final byte value;
	private final String text;

	LockedEnum(byte value, String text) {
		this.value = value;
		this.text = text;
	}

	/**
	 * Gets value.
	 *
	 * @return the value
	 */
	public byte getValue() {
		return value;
	}

	/**
	 * Gets text.
	 *
	 * @return the text
	 */
	public String getText() {
		return text;
	}

	/**
	 * 
	 * @param value
	 * @return
	 */
	public static LockedEnum getByValue(byte value) {
		for (LockedEnum temp : LockedEnum.values()) {
			if (temp.getValue() == value) {
				return temp;
			}
		}
		return null;
	}

}
